package com.ruoyi.base.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 订单操作对象 base_fruit_order
 *
 * @author ruoyi
 * @date 2024-01-23
 */
@Data
public class BaseFruitOrder extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 订单编号
     */
    private Long id;

    /**
     * 客户公司
     */
    @Excel(name = "客户公司")
    private String companyName;

    /**
     * 订单金额
     */
    @Excel(name = "订单金额")
    private Long orderMoney;

    /**
     * 销售人
     */
    @Excel(name = "销售人")
    private String saleBy;

    /**
     * 联系方式
     */
    @Excel(name = "联系方式")
    private Long telNum;

    /**
     * 销售时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "销售时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date saleTime;

    private List<BaseFruitOrderDetail> orderItemList;



    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("companyName", getCompanyName())
                .append("orderMoney", getOrderMoney())
                .append("saleBy", getSaleBy())
                .append("createTime", getCreateTime())
                .append("remark", getRemark())
                .append("telNum", getTelNum())
                .append("saleTime", getSaleTime())
                .toString();
    }
}
